let processData = (d) => {
	let data = {
		name: d.name,
		duration: d.duration,
		startTime: d.startTime,
		entryType: d.entryType
	}
	return data
}
export default {
	init(cb) {
		window.onload = function () {
			// 获取资源相关的信息
			let performanceData = performance.getEntriesByType('resource')
			let data = performanceData.map((_) => processData(_))
			console.log(data)
			cb(data)
		}
	}
}
